const Sequelize = require('sequelize')
const DBConnectConfig = require(process.cwd() + '/src/config/app_config').DB_CONFIG

module.exports = new Sequelize(
  DBConnectConfig.database, DBConnectConfig.username, DBConnectConfig.password,
  {
    host: DBConnectConfig.host,
    port: DBConnectConfig.port,
    dialect: DBConnectConfig.dialect,
    pool: DBConnectConfig.pool,
    timezone: DBConnectConfig.timezone,
    underscored: DBConnectConfig.underscored,
    operatorsAliases: DBConnectConfig.operatorsAliases,
    logging: DBConnectConfig.logging
  }
)
